﻿@model IEnumerable<StudentInfo.Areas.StudentArea.ViewModels.MarkDetailsViewModel>
@using StudentInfo.HtmlHelpers 

@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/_Layout.cshtml";
}

<h2>Оценки</h2>

<p>
    @Html.ImageActionLink("/Content/Images/create.png", "Create", null)
  
</p>
<table>
    <tr>
        <th></th>
        <th>
            @Html.LabelFor(model => model.First().StudentName)
        </th>
        <th>
            @Html.LabelFor(model => model.First().ExamName)
        </th>
        <th>
            @Html.LabelFor(model => model.First().Result)
        </th>
    </tr>

@foreach (var item in Model) {
    <tr>
        <td>
            @Html.ImageActionLink("/Content/Images/edit.png", "Edit", new { markId = item.Id })                                                                           
            @Html.ImageActionLink("/Content/Images/view.png", "Details", new { markId = item.Id }) 
            @Html.ImageActionLink("/Content/Images/delete.png", "Delete", new { markId = item.Id })
        </td>
        <td>
            @item.StudentName
        </td>
        <td>
            @item.ExamName
        </td>
        <td>
            @item.Result
        </td>
    </tr>
}
</table>
